/**
 * C Programming: A Modern Approach
 *
 * version: 2nd
 * author: K.N.King
 * http://knking.com/books/c2
 */

#include <stdio.h>

/**
 * Computes the dimensional weight of a 12*10*8 box
 */

int main(void) {
    int height = 8;
    int length = 12;
    int width = 10;

    int volume;
    int weight;

    volume = height * length * width;
    weight = (volume + 165) / 166;

    printf("Dimensions: %d*%d*%d\n", length, width, height);
    printf("Volume (cubic inches): %d\n", volume);
    printf("Dimensional weight (pounds): %d\n", weight);

    return 0;
}

/*
output:
Dimensions: 12*10*8
Volume (cubic inches): 960
Dimensional weight (pounds): 6
*/